package io.zhifei.modules.sys.system.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.zhifei.modules.sys.system.entity.SysLive;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Map;

@Mapper
public interface SysLiveDao extends BaseMapper<SysLive> {
    /**
     * 获取直播列表
     *
     * @param page
     * @param type
     * @return
     */
    Page<Map<String, Object>> getLiveList(Page page, @Param("type") String type);

    /***
     * 获取该课程是否还有未直播的内容
     * @param courseId
     * @return
     */
    int getLiveCount(@Param("courseId") String courseId);
}
